package com.gopay.common.cps.dao.ic.impl;

/*
 * Copyright (c) 2016. www.gopay.com.cn Inc.All rights reserved.
 * 项目名称 : 国付宝内部对账(2016/11/29)
 * 文件名称 : IcTrialBalanceDAOImpl
 * 创建日期 : 16-12-22 下午2:26
 * Author   : baiyunpeng
 *
 */

import com.gopay.common.base.dao.impl.BaseDAOImpl;
import com.gopay.common.cps.dao.ic.IcTrialBalanceDAO;
import com.gopay.common.domain.ic.IcTrialBalance;
import org.springframework.stereotype.Repository;

import java.io.Serializable;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

@Repository("IcTrialBalanceDAO")
public class IcTrialBalanceDAOImpl extends BaseDAOImpl<IcTrialBalance, Serializable> implements IcTrialBalanceDAO {
    @Override
    public List<IcTrialBalance> getIcTrialByCheckDate(Map<String, Object> dataMap) {
        Map<String, Object> map = new HashMap();
        String insertDate = dataMap.get("insertDate").toString().substring(0, 8);
        map.put("CHECK_DATE", insertDate);
        return findByHql("from IcTrialBalance where checkDate=:CHECK_DATE", map);
    }
}
